package com.bosssoft.gateway.authentication.api;

import com.bosssoft.gateway.authentication.pojo.query.LoginQuery;
import common.annotation.ApiLog;
import common.data.commonresponse.CommonResponse;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;

/**
 * @className: AuthenticationApi
 * @description: 认证api层，用于访问用户中心的认证方法，并生成token
 * @author: lanyukai
 * @date: 2024/6/19 16:48
 * @since 1.0
 **/
@Api(tags = "认证接口", value = "/auth")
@RequestMapping("/api/v1/permission")
@Validated
public interface AuthenticationApi {
    @ApiOperation(tags = "登录认证", value = "token")
    @GetMapping("/auth")
    CommonResponse<String> doAuth(@NotNull @Valid LoginQuery loginQuery);
}
